<!-- eslint-disable prettier/prettier -->
<script setup lang="ts">
import { ref, computed } from 'vue'
const array = ref([1, 2, 3, 4, 5, 6, 7, 8, 9, 10])
// 展示过滤或排序后的结果
const computedArray = computed(() => {
   return array.value.filter((item:number)=>item > 5)
})
const show = ref(false)
</script>
<!-- eslint-disable prettier/prettier -->
<template>
  <div>
    <ul>
      <li v-for="item in computedArray" :key="item">{{ item }}</li>
    </ul>
  </div>
</template>
<!-- eslint-disable prettier/prettier -->
<style scoped lang="scss"></style>
